﻿
@{
    ViewBag.Title = "Index";
    Layout = "~/Views/Shared/MainLayout.cshtml";
}
<script type="text/javascript">
    $(function () {
        //导航切换
        $(".menuson li.active").removeClass("active");
        $("#teacherItem").addClass("active");
    });
</script>
<div class="place">
    <span>位置：</span>
    <ul class="placeul">
        <li><a href="#">首页</a></li>
        <li><a href="#">顾问信息</a></li>
    </ul>
</div>

<div class="rightinfo" style=" border:0px solid red;">
    <div class="tools" style=" border:0px solid green;">
        <ul class="toolbar">
            <li class=""><a href="/Teacher/Create"><span><img src="~/images/t01.png" /></span>添加</a></li>
        </ul>
        <ul class="toolbar1">
            <li><span><img src="~/images/t05.png" /></span>设置</li>
        </ul>
        <div style="clear:both"></div>
    </div>
    <table class="tablelist">
        <thead>
            <tr>
                <th>编号<i class="sort"><img src="~/images/px.gif" /></i></th>
                <th>顾问姓名</th>
                <th>登录名</th>
                <th>性别</th>
                <th>电话</th>
                <th>邮箱</th>
                <th>角色</th>
                <th>操作</th>
            </tr>
        </thead>
        <tbody>
            @foreach (var item in ViewData["teachers"] as List<HRSM.Models.Teacher>)
            {
                <tr>
                    <td>
                        @item.ID
                    </td>
                    <td>
                        @item.Name
                    </td>
                    <td>
                        @item.LoginName
                    </td>
                    <td>
                        @if (item.Sex)
                        {
                            <lable>男</lable>
                        }
                        else
                        {
                            <lable>女</lable>
                        }
                    </td>
                    <td>
                        @item.Phone
                    </td>
                    <td>
                        @item.Email
                    </td>
                    <td>
                        @item.Roles
                    </td>
                    <td>
                        @Html.ActionLink("编辑", "Edit", new { id = item.ID }, new { @class = "tablelink" }) |
                        @Html.ActionLink("查看", "Details", new { id = item.ID }, new { @class = "tablelink" }) |
                        @Html.ActionLink("删除", "Delete", new { id = item.ID }, new { @class = "tablelink" })
                    </td>
                </tr>
            }
        </tbody>
    </table>
    <div class="pagin">
        <div class="message">共<i class="blue">123</i>条记录，当前显示第&nbsp;<i class="blue">1&nbsp;</i>页</div>
        <ul class="paginList">
            <li class="paginItem"><a href="javascript:;"><span class="pagepre"></span></a></li>
            <li class="paginItem"><a href="javascript:;">1</a></li>
            <li class="paginItem current"><a href="javascript:;">2</a></li>
            <li class="paginItem"><a href="javascript:;">3</a></li>
            <li class="paginItem"><a href="javascript:;">4</a></li>
            <li class="paginItem"><a href="javascript:;">5</a></li>
            <li class="paginItem more"><a href="javascript:;">...</a></li>
            <li class="paginItem"><a href="javascript:;">10</a></li>
            <li class="paginItem"><a href="javascript:;"><span class="pagenxt"></span></a></li>
        </ul>
    </div>
</div>
<script type="text/javascript">
    $('.tablelist tbody tr:odd').addClass('odd');
</script>


